package br.com.gerenciador_recursos.servlets;

import java.io.IOException;
import java.util.List;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import br.com.gerenciador_recursos.model.User;
import br.com.gerenciador_recursos.service.UserLocalServiceUtil;
import br.com.gerenciador_recursos.util.Constants;
import br.com.gerenciador_recursos.util.ParamUtil;

public class CadastroEntidadesServlet extends HttpServlet {

	private static final long serialVersionUID = 1L;

	public CadastroEntidadesServlet() {
		super();
	}

	@Override
	protected void service(HttpServletRequest req, HttpServletResponse res)
			throws ServletException, IOException {
		
		System.out.println("MyViewServlet");

		String cmd = ParamUtil.getString(req, Constants.CMD);
		
		if(cmd.equals(Constants.LIST_PROJECT)){
			
			
		}else if(cmd.equals(Constants.LIST_TASK)){
			
			
		}else if(cmd.equals(Constants.LIST_USER)){
			
			List<User> users = UserLocalServiceUtil.findAll();
			
			
		}else if(cmd.equals(Constants.MY_VIEW)){
			
			
		}
		
	}

}
